home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
By Popular Request 2.0
/
By Popular Request 2.0 (Arsenal Computer).ISO
/
amiga_1
/
amsls495.lzh
/
AMOSLIST
/
000038_amos-request@svcs1.digex.net_Sat Apr 8 13:34:54 1995.msg
< prev
next >
Wrap
Internet Message Format
|
1995-05-01
|
2KB
Received: from svcs1.digex.net by nfs1.digex.net with SMTP id AA14962
(5.67b8/IDA-1.5); Sat, 8 Apr 1995 13:34:52 -0400
Received: by svcs1.digex.net id AA09561
(5.67b8/IDA-1.5 for amos-out); Sat, 8 Apr 1995 09:24:41 -0400
Received: from nfs2.digex.net by svcs1.digex.net with SMTP id AA09557
(5.67b8/IDA-1.5 for <amos@svcs1.digex.net>); Sat, 8 Apr 1995 09:24:39 -0400
Received: from goober.mbhs.edu by nfs2.digex.net with SMTP id AA06282
(5.67b8/IDA-1.5 for <amos-list@access.digex.net>); Sat, 8 Apr 1995 09:24:05 -0400
Received: from dragon.mbhs.edu by goober.mbhs.edu (AIX 3.2/UCB 5.64/4.03)
id AA20364; Sat, 8 Apr 1995 09:25:50 -0400
Date: Sat, 8 Apr 1995 09:25:50 -0400
Message-Id: <9504081325.AA20364@goober.mbhs.edu>
From: achurch@dragon.mbhs.edu (Andy Church)
To: amos-list@access.digex.net
Subject: Re: stdin/stdout
Reply-To: achurch@goober.mbhs.edu
X-Mailer: MMail v4.20
Status: O
X-Status:
> 2: <This method is a little trickier but not too difficult>
If you use this, you need to make the changes indicated below:
Old New
--- ---
A$="*"
Areg(1)=Varptr(A$) Dreg(1)=Varptr(A$)
Dreg(2)=1005
MYIO=Doscall(LVO("Open")) (or) MYIO=Doscall(-30)
> Then you use the contents of MYIO and use the following fragments
> to do IO:
IN:
inbuf$=space$(30)
areg(1)=MYIO Dreg(1)=MYIO
areg(2)=Varptr(inbuf$) Dreg(2)=Varptr(INBUF$)
dreg(0)=1 Dreg(3)=Len(INBUF$)
z=Doscall(LVO("Read")) (or) z=Doscall(-42)
OUT:
outbuf$="Hello world"
areg(1)=MYIO Dreg(1)=MYIO
areg(2)=Varptr(outbuf$) Dreg(2)=Varptr(OUTBUF$)
Dreg(3)=Len(OUTBUF$)
z=Doscall(LVO("Write")) (or) z=Doscall(-48)
> Finally, when you are done, you have to close the file:
areg(1)=MYIO Dreg(1)=MYIO
z=Doscall(LVO"Close") z=Doscall(LVO("Close"))
(or) z=Doscall(-36)
>I don't know the numbers by heart either... drat. If you have the RKM
>look up "Interactive". That's the mode you want.
>
>This: Dreg(0)=Label("IsInteractive") will probably do it.
No - IsInteractive is a function that returns whether a file is
interactive (e.g. a Shell window). The mode, as shown above, is 1005
(AmigaDOS's MODE_OLDFILE).
--Andy Church (achurch@goober.mbhs.edu)
WWW: http://www.mbhs.edu/~achurch/
AMOS Web Site: http://www.mbhs.edu/~achurch/amos/